<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateFangownersTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('fangowners', function (Blueprint $table) {
            $table->bigIncrements("id");
            $table->string("name",50)->comment("房东姓名");
            $table->enum("sex",["男","女"])->default("男")->comment("房东性别");
            $table->unsignedTinyInteger("age")->default(20)->comment("房东年龄");
            $table->char("phone",15)->comment("电话号码");
            $table->string("card",20)->comment("身份证号码");
            $table->string("address",100)->comment("家庭住址");
            $table->string("pid",500)->comment("身份证照片");
            $table->string("email",50)->default()->comment("邮箱");
            $table->softDeletes();
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('fangowners');
    }
}
